package com.examplemartin.jpademo.dao;

import com.examplemartin.jpademo.pojo.po.purchase.PurPO;

import java.util.List;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
import org.springframework.stereotype.Repository;

@Repository
public interface PurchaseDao extends JpaRepository<PurPO,Long> , JpaSpecificationExecutor<PurPO> {

  /**
   * 1 按生成日期降序
   * 2 按状态查找
   * @param status
   * @return
   */
  List<PurPO> findByStatusOrderByCreateTimeDesc(Integer status);



}
